home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 21 / AACD 21.iso / AACD / Utilities / Ghostscript / src / icharout.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-01-01  |  2.6 KB  |  74 lines

  1. /* Copyright (C) 1996, 1997, 1998, 1999, 2000 Aladdin Enterprises.  All rights reserved.
  2.   
  3.   This file is part of AFPL Ghostscript.
  4.   
  5.   AFPL Ghostscript is distributed with NO WARRANTY OF ANY KIND.  No author or
  6.   distributor accepts any responsibility for the consequences of using it, or
  7.   for whether it serves any particular purpose or works at all, unless he or
  8.   she says so in writing.  Refer to the Aladdin Free Public License (the
  9.   "License") for full details.
  10.   
  11.   Every copy of AFPL Ghostscript must include a copy of the License, normally
  12.   in a plain ASCII text file named PUBLIC.  The License grants you the right
  13.   to copy, modify and redistribute AFPL Ghostscript, but only under certain
  14.   conditions described in the License.  Among other things, the License
  15.   requires that the copyright notice and this notice be preserved on all
  16.   copies.
  17. */
  18.  
  19. /*$Id: icharout.h,v 1.2.2.1 2000/10/26 12:45:12 igorm Exp $ */
  20. /* Interface to zcharout.c */
  21.  
  22. #ifndef icharout_INCLUDED
  23. #  define icharout_INCLUDED
  24.  
  25. /* Execute an outline defined by a PostScript procedure. */
  26. int zchar_exec_char_proc(P1(i_ctx_t *));
  27.  
  28. /*
  29.  * Get the metrics for a character from the Metrics dictionary of a base
  30.  * font.  If present, store the l.s.b. in psbw[0,1] and the width in
  31.  * psbw[2,3].
  32.  */
  33. typedef enum {
  34.     metricsNone = 0,
  35.     metricsWidthOnly = 1,
  36.     metricsSideBearingAndWidth = 2
  37. } metrics_present;
  38. int /*metrics_present*/
  39.   zchar_get_metrics(P3(const gs_font_base * pbfont, const ref * pcnref,
  40.                double psbw[4]));
  41.  
  42. /* Get the vertical metrics for a character from Metrics2, if present. */
  43. int /*metrics_present*/
  44.   zchar_get_metrics2(P3(const gs_font_base * pbfont, const ref * pcnref,
  45.             double pwv[4]));
  46.  
  47. /*
  48.  * Consult Metrics2 and CDevProc, and call setcachedevice[2].  Return
  49.  * o_push_estack if we had to call a CDevProc, or if we are skipping the
  50.  * rendering process (only getting the metrics).
  51.  */
  52. int zchar_set_cache(P9(i_ctx_t *i_ctx_p, const gs_font_base * pbfont,
  53.                const ref * pcnref, const double psb[2],
  54.                const double pwidth[2], const gs_rect * pbbox,
  55.                int (*cont_fill) (P1(i_ctx_t *)),
  56.                int (*cont_stroke) (P1(i_ctx_t *)),
  57.                const double Metrics2_sbw_default[4]));
  58.  
  59. /*
  60.  * Get the CharString data corresponding to a glyph.  Return typecheck
  61.  * if it isn't a string.
  62.  */
  63. int zchar_charstring_data(P3(gs_font *font, const ref *pgref,
  64.                  gs_const_string *pstr));
  65.  
  66. /*
  67.  * Enumerate the next glyph from a directory.  This is essentially a
  68.  * wrapper around dict_first/dict_next to implement the enumerate_glyph
  69.  * font procedure.
  70.  */
  71. int zchar_enumerate_glyph(P3(const ref *prdict, int *pindex, gs_glyph *pglyph));
  72.  
  73. #endif /* icharout_INCLUDED */
  74.